package com.sk.bilibili.adapter.pager.main;

import androidx.annotation.NonNull;
import androidx.fragment.app.Fragment;
import androidx.fragment.app.FragmentManager;

import com.sk.bilibili.adapter.pager.BaseFragmentAdapter;
import com.sk.bilibili.view.fragment.main.home.home.FilmFragment;
import com.sk.bilibili.view.fragment.main.home.home.HotFragment;
import com.sk.bilibili.view.fragment.main.home.home.LiveFragment;
import com.sk.bilibili.view.fragment.main.home.home.RecommendFragment;
import com.sk.bilibili.view.fragment.main.home.home.ThemFragment;

public class HomeFragmentAdapter extends BaseFragmentAdapter {

    public HomeFragmentAdapter(@NonNull FragmentManager fm) {
        super(fm);
        initData();
    }

    @Override
    protected String[] getTitles() {
        return "直播,推荐,热门,追番,影视".split(",");
    }

    @Override
    protected Fragment[] getFragments() {
        Fragment[] fragments=new Fragment[5];
        fragments[0]=new LiveFragment();
        fragments[1]=new RecommendFragment();
        fragments[2]=new HotFragment();
        fragments[3]=new ThemFragment();
        fragments[4]=new FilmFragment();
        return fragments;
    }

}